home *** CD-ROM | disk | FTP | other *** search
/ Garbo / Garbo.cdr / mac / hypercrd / hc2_x / tcprogud.sit / TC Prog Guide / card_23578.txt < prev    next >
Text File  |  1991-02-27  |  911b  |  25 lines

  1. -- card: 23578 from stack: in
  2. -- bmap block id: 0
  3. -- flags: 0000
  4. -- background id: 4755
  5. -- name: 
  6.  
  7.  
  8. -- part contents for background part 4
  9. ----- text -----
  10. FLOATING-POINT NUMBERS
  11.  
  12. Floating-point variables are declared using the 'float' type specifier, and floating point constants are indicated by a decimal point:
  13.  
  14.     float    standard_deviation;
  15.     standard_deviation = 0.;
  16.  
  17. Double-precision floating-point variables use the 'double' specifier, usually occuping 64 bits instead of a float's 32 bits.  Floating-point constants are double by default.  In Think C, arithmetic using doubles is faster that that using float variables.  
  18.  
  19. An alternate representation of floating-point constants uses "e" notation to indicate the number is to be multiplied by 10 raised to the indicated exponent:
  20.  
  21.     standard_deviation = 1e-4;     /*  same as .0001  */
  22.  
  23. -- part contents for background part 7
  24. ----- text -----
  25. 54